package com.teamwork.ZuccEcho.Service.impl;

import com.teamwork.ZuccEcho.Entity.Model;
import com.teamwork.ZuccEcho.Repository.ModelApiRepository;
import com.teamwork.ZuccEcho.Service.ModelService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;
@Service
public class ModelServiceImpl implements ModelService {
    @Autowired
    private ModelApiRepository modelApiRepository;
    @Override
    public List<Model> getModelList() {
        return modelApiRepository.findAll();
    }

    @Override
    public Model findModelById(long id) {
        return modelApiRepository.findById(id);
    }
}
